<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@ taglib prefix="fns" uri="/WEB-INF/tlds/fns.tld" %>
<c:set var="ctx" value="${pageContext.request.contextPath}${fns:getAdminPath()}"/>
<c:set var="ctxMobileSite" value="${pageContext.request.contextPath}/site"/>
<c:set var="ctxStatic" value="${pageContext.request.contextPath}/static"/>
<c:set var="ctxImages" value="${pageContext.request.contextPath}/userfiles/project"/>
<c:set var="ctxUser" value="${pageContext.request.contextPath}/userfiles"/>
<c:set var="ctxRoot" value="${pageContext.request.contextPath}"/>
<c:set var="ctxTheme" value="${fns:getCache('theme', theme)}"/>
<c:set var="ctxPage" value="/WEB-INF/views/modules/site"/>
<!DOCTYPE html>
<html lang="zh-CN"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <meta charset="UTF-8">
    <meta name="HandheldFriendly" content="True">
    <meta name="format-detection" content="telephone=no">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <meta name="format-detection" content="telephone=no">
    <meta http-equiv="cleartype" content="on">
    <title>投票 </title>
    <link rel="stylesheet" href="${ctxStatic }/site/themes/HongJiuMuBan/wap.css">
    <script type="text/javascript">
    var _global = {"kdt_id":"20751","user_id":0,"run_mode":"online","debug":false,"project":"default","online_debug":true,"js":{"js_compress":true,"message_report":true,"checkbrowser":true,"hide_wx_nav":true,"qn_public":"kdt_img","qn_private":"kdt-private"},"query_path":"\/showcase\/feature","module":"showcase","controller":"Showcase_Feature_Controller","action":"index","full_action":"getIndexHtml","method":"get","format":"html","page_size":760,"is_mobile":false,"isShopDomain":false,"from_weibo":false,"mp_changed":true,"is_owner_team":false,"fans_id":0,"is_fans":2,"mp_id":"14657","mp_data":{"mp_id":"14657","kdt_id":"20751","mp_weixin":"SMT88888519","mp_nickname":"\u9152\u7ba1\u5bb6","is_display_footbar":"1","is_display_suffix_name":"0","suffix_name":"","logo":"http:\/\/imgqn.koudaitong.com\/upload_files\/2014\/05\/17\/FrR4S1-eZAbVRpxGT-DK0STkiKxx.png","team_name":"\u9152\u7ba1\u5bb6\u65d7\u8230\u5e97","intro":"\u9152\u7ba1\u5bb6\u5021\u5bfc\u666e\u53ca\u7ea2\u9152\u6587\u5316\uff0c\u5f15\u9886\u5065\u5eb7\u751f\u6d3b\uff0c\u81f4\u529b\u4e8e\u63d0\u4f9b\u53ca\u65f6\u8d44\u8baf\u548c\u4f01\u4e1a\u5ba3\u4f20\uff0c\u901a\u8fc7\u8461\u8404\u9152\u7535\u5546\u5e73\u53f0\uff0c\u4e3a\u5e7f\u5927\u8461\u8404\u9152\u7231\u597d\u8005\u63d0\u4f9b\u5168\u65b9\u4f4d\u7684\u4f18\u8d28\u670d\u52a1\u3002\u54c1\u8d28\u4fdd\u8bc1\uff0c\u6b22\u8fce\u54c1\u9274\u3002"},"source":"","ajaxURL":{"isFans":"http:\/\/koudaitong.com\/v1\/api\/fans\/check?fans_mi=14657"},"logURL":"http:\/\/tj.koudaitong.com\/1.gif","no_sidebar":0,"url":{"base":"http:\/\/koudaitong.com","domain":"koudaitong.com","cp":"http:\/\/cp.koudaitong.com","pay":"http:\/\/pay.koudaitong.com","trade":"http:\/\/trade.koudaitong.com","wdp_wap":"http:\/\/m.wdianpu.com","wdp":"http:\/\/www.wdianpu.com","api":"http:\/\/api.koudaitong.com","img":"http:\/\/img.koudaitong.com","static":"http:\/\/static.koudaitong.com\/v2","www":"http:\/\/koudaitong.com\/v2","v1":"http:\/\/koudaitong.com\/v1","short_url":"http:\/\/koudaitong.com","v1_static":"http:\/\/static.koudaitong.com\/v1","wap":"http:\/\/wap.koudaitong.com\/v2","imgqn":"http:\/\/imgqn.koudaitong.com","goods_search":"http:\/\/10.6.5.28:8899","callback_queue":"http:\/\/10.6.5.28:8899\/queue","log_url":"http:\/\/tj.koudaitong.com\/1.gif","cron":"http:\/\/10.6.5.28:1934\/","taobao_item":"http:\/\/item.taobao.com","scv":"http:\/\/scv.koudaitong.com","open":"http:\/\/open.koudaitong.com","qrcode":"http:\/\/10.6.5.28:8080\/qr?","taobao_wap_item":"http:\/\/a.m.taobao.com","v2":"http:\/\/koudaitong.com\/v2","static_host":"http:\/\/static.koudaitong.com"}};    _global.spm = {logType:"f",logId:"1094604"};
    </script> 
    <script type="text/javascript">
    (function(ua) {
        var ele = document.documentElement;
        if (ua.match(/micromessenger\/5/gi)) {
            ele.className = ele.className + ' mobile wx_mobile wx_mobile_5';
        } else if (ua.match(/micromessenger/gi)) {
            ele.className = ele.className + ' mobile wx_mobile';
        } else if (window._global.is_mobile) {
            ele.className = ele.className + ' mobile'
        }
    })(navigator.userAgent || navigator.vendor || window.opera)
    
    function add(questionId){
    	$.get( "${ctxRoot }/wechat/questionnaireReply/addQuestionNumber/"+questionId, function( data ) {
    		if(data==='no'){
    			alert("您已经投过了");
    		}
    		if(data==='ok'){
    			var number=parseInt($( "#number"+questionId ).html());
    			$("#number"+questionId).animate({ top: '+=20px', opacity: '0' }, "slow", function () { //让数字向下移动并消失，top为元素距网页顶部距离，opacity为透明度，值为0~1
    				$( "#number"+questionId ).html(number+1); //等数字消失后变为n，网页里有id为counter的一个span元素，这段代码必须放在animate里边，否则数字消失之前它的数值就改变了
    		    	})	.animate({ top: '-=40px' }, "slow") //数字n跳至原来位置的上方
    		    	.animate({ top: '+=20px', opacity: '1' }, "slow"); //数字n出现并落至数字原来位置，opacity为0时是对象完全透明，就是消失，值为1时是完全显现
    		}
    		});
    }
    </script>
</head>
<body style="padding-bottom: 40px;">
<div class="container ">
<div class="content js-mini-height">
       <div class="content-body">
         <ul class="custom-image clearfix">
         <c:forEach items="${questionList }" var="question">
           <li class="custom-image-small"  style="height:200px;">
             <a class="" href="${ctxRoot }/wechat/questionnaireReply/viewQuestion/${question.id }"   >
               <img src="${ctxUser }/questionnaire/${question.showPic }" style="display: block;" class="js-lazy" height="269.71428571429" width="320">
               </a>
              <h3 class="title"  align="center">${question.voterName }<br/><span style="float:left;"  onclick="add(${question.id });">❤赞</span><span id="number${question.id }" style="float:right;margin-right:3px;">${question.number }</span> </h3>
            </li>
            </c:forEach>
           </ul>
       </div>                                                        
    </div>

    <div class="js-footer" style="min-height: 1px;">
      <div class="footer">
          <p class="copyright"><a href="tel:03107056607" target="_blank">技术支持：邯郸智讯</a></p>
      </div>
    </div>
    
</div>

<div id="js-fuck-taobao" class="fullscreen-guide fuck-taobao hide">
    <span class="js-close-taobao guide-close">×</span>
    <span class="guide-arrow"></span>
    <div class="guide-inner">
    <div class="step step-1"></div>
    <div class="js-step-2 step"></div>
</div>

</div>

<script>
(function(b){function c(){}for(var d="assert,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,markTimeline,profile,profileEnd,time,timeEnd,trace,warn".split(","),a;a=d.pop();)b[a]=b[a]||c})(window.console=window.console||{});
</script>
<script src="${ctxStatic }/site/themes/HongJiuMuBan/jquery.js"></script>
<script src="${ctxStatic }/site/themes/HongJiuMuBan/underscore-min.js"></script>
<script src="${ctxStatic }/site/themes/HongJiuMuBan/idangerous.js"></script>
<script src="${ctxStatic }/site/themes/HongJiuMuBan/wap.js"></script>
<script src="${ctxStatic }/site/themes/HongJiuMuBan/fullguide.js"></script>
</body></html>